package java_test.mtthod.overriding;

public class Figure {
    double dim1;
    double dim2;

    Figure(double a, double b) {
        dim1 = a;
        dim2 = b;
    }

    double area() {
//        在第一次的调用中会进行赋值 得到 10 10
        System.out.println("Inside area for figure.");
        return (dim1 * dim2);
    }
}
